package lex.dm.ui.actions;

import java.awt.event.ActionEvent;
import java.io.File;
import lex.dm.DTree;
import lex.dm.loader.AbstractDataLoader;
import lex.dm.loader.WDBCLoader;
import lex.dm.loader.WisconsinBreastCancerLoader;
import lex.dm.utils.Prefs;

public class WDBCAction extends AbstractLoadAction
{
	private WDBCLoader loader = null;

	public WDBCAction()
	{
		this.setName( "WDBC" );
	}

	@Override
	protected File getDataFile()
	{
		return Prefs.getWDBCFile();
	}

	@Override
	protected AbstractDataLoader getDataLoader()
	{
		if( null == loader )
			loader = new WDBCLoader( DTree.getApplication().getConnection(),
				Prefs.WDBC_TABLE );
		return loader;
	}
}
